package com.javen.controller;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.servlet.ModelAndView;

import com.javen.service.ILoginService;

@Controller // 告诉Spring 这里是一个控制器，你得管
@RequestMapping("/login") // 告诉SpringMVC 这里有路径--字符串全项目不能重复
public class LoginController {

	@Autowired
	private ILoginService loginService;

	@RequestMapping("/index")
	public ModelAndView index(HttpServletRequest request,HttpServletResponse response ,ModelAndView view) {
//		
//
//		String parameter = request.getParameter("id");
//		if (null != parameter && !parameter.equals("")) {
//			 id = Integer.valueOf(parameter);
//		}else {
//			System.err.println(id);
//		}
////		Login check = new Login();
////		check.setId(id);
////		loginService.checkLogin(check);
//		view.setViewName("login1/index1");
		return view;
	}
}
